// void, Obj This, ObjList ol, point pt

Ship this;
Unit u;
ObjList olInShip, olWagon;
int i;

this = This.AsShip;
		
while( ! .Goto( pt, 0, 1000, true, -1 ))
{
	if( .TimeWithoutWalking > 0 ) break;
}
.UnboardUnits( ol );

olInShip = .GetUnitsOnBoard; 

for(i=0; i<olInShip.count; i+=1) {
	u = olInShip[i].AsUnit;
	if(u.IsHeirOf("Wagon")){
		olWagon.Add(u);
	} 
}
.UnboardUnits( olWagon );
